• Extend Create Policy

    OIPA now has the ability to optionally insert pending activities or programs on a new policy as it is created with the CreatePolicy APE. New Configuration is added to the Create Policy APE on Create Policy transaction in the Functional Prototype Plan to Illustrate this functionality

    When a new policy is inserted using the CreatePolicy APE, configuration should support simultaneously inserting pending activities into the new policy similar to a Spawn section of a transaction. The activities should be conditionally created based on evaluation of a test criterion.

    Likewise, when a new policy is inserted using an the CreatePolicy APE, configuration should support simultaneously inserting segment or policy level Programs to the new policy similar to how the segments are built in the CreateSegments APE. The Programs should also be conditionally created based on evaluation of a test criterion.

    Business Rules

    Activities element

    A new optional element called “Activities” is available to the CreatePolicy APE. Within this element will be a repeatable “Activity” element that will contain the activity spawn instructions.

    TRANSACTION – is a required attribute of Activity and accepts a literal string transaction name from AsTransaction.

    When processing, using best match, the system will resolve the TransactionGUID of the named transaction to create for the current policy plan.

    If a TransactionGUID for the named transaction is not found, the activity will process without error but the pending activity will not be inserted

    An optional Tests element containing a repeatable Test element will allow the system to conditionally create the specified Activity.

    Test – is a repeatable element that accepts references to literal strings, fields or transaction math variables in a comparison operation that resolves to true or false.

    • All tests are implicitly “AND” operations and if multiple test elements exist, all must resolve to true in order for the activity to be inserted.
    • This should use standard Tests and Test evaluation logic in the system.
    • The Fields element within Activity will hold a repeatable Field element. Inside each Field element will be From and To elements to specify the values for the named transaction.

    From – is a required element specifying a field or transaction math variable that specifies a source value to insert

    • When processing, if the specified From field or math variable does not exist in the parent activity a stack trace error will be thrown indicating the value does not exist.

    To – is a required element specifying a literal field name to populate on the pending activity

    When processing, if the specified To field does not exist in the defined fields of the named transaction, that field is not inserted into AsActivityField and no error will be thrown.

    The activity effective date o the named transaction may be set using the From and To field syntax where the To field is “EffectiveDate”. Alternately, if the field is not specified, the activity effective date will by default be the same as the parent transaction.

    Processing the APE for Activities
    • When the CreatePolicy APE executes, the system will determine if the Activities element exists
    • If Activities exist and all Test elements for that activity resolve to ‘true’ the system will resolve the transaction name to create
    • As with a transaction Spawn, only the fields explicitly listed in the Fields section of the APE will be inserted on the new pending activity.
    • If Activities exist and any Test element for that activity resolves to ‘false’ the system will not create that activity.
    Policy and Segment Programs

    Programs may be added at the policy and/or segment level through the CreatePolicy APE. The configuration for the Programs element will be identical for these two sections of the rule.

    Programs element

    A new optional element called “Programs” is available to the CreatePolicy APE. The element may be added to the root CreatePolicy element or to the Segment element. Within this element will be a repeatable “Program” element that will contain the program instructions.

    PROGRAMNAME – is a required attribute of Program and accepts a literal string program name from AsProgramDefinition.

    When processing at the CreatePolicy root element level, using best match, the system will resolve the ProgramDefinitionGUID of the named program to create for the current policy plan on AsPlanProgramDefinition.

    When processing at the Segment element level, using best match, the system will resolve the ProgramDefinitionGUID of the named program to create for the current plan segment on AsSegmentProgramDefinition.

    If a ProgramDefinitionGUID for the named program is not found, the activity will process without error but the program will not be inserted

    PROCESSPROGRAM – is an optional attribute of Program and accepts a literal string value of ‘Yes’ or ‘No’ with the default value of ‘No’.

    If the value is set to Yes, the program will process to an active state as the policy is created. The database will be updated just as though a user had clicked through the processing buttons for the program and each historical status change of the sequence will be captured and stored. (Pending Ready to Ready).

    If the value is set to No or the attribute is omitted, only the pending program will be inserted on the newly created policy.

    An optional Tests element containing a repeatable Test element will allow the system to conditionally create the specified program.

    Test – is a repeatable element that accepts references to literal strings, fields or transaction math variables in a comparison operation that resolves to true or false.

    All tests are implicitly “AND” operations and if multiple test elements exist, all must resolve to true in order for the program to be inserted.

    This should use standard Tests and Test evaluation logic in the system.

    The Fields element within Program will hold a repeatable Field element. Inside each Field element will be From and To elements to specify the values for the named transaction.

    From – is a required element specifying a field or transaction math variable that specifies a source value to insert

    When processing, if the specified From field or math variable does not exist in the parent activity a stack trace error will be thrown indicating the value does not exist.

    To – is a required element specifying a literal field name to populate on the program

    When processing, if the specified To field does not exist in the defined fields of the named program definition, that field is not inserted into AsProgramField and no error will be thrown.

    Processing the APE for Programs

    • When the CreatePolicy APE executes, the system will determine if the Programs element exists either within the root of the APE or the Segment element.
    • If Program exists its Test element resolves to ‘true’ the system will resolve the program to create
    • As with a transaction Spawn, only the fields explicitly listed in the Fields section of the APE will be inserted on the new program
    • After inserting the records into AsProgram, AsProgramFields, and AsPolicyProgram or AsSegmentProgram, the system will process the ProgramActions section of the ProgramDefinition
    • Only the ProgramAction specifying ACTION=”Start” will be executed thereby inserting a pending program start activity.
    • If Program exists and its Test element resolves to ‘false’ the system will not create that program.